/*
*  Copyright 2019-2020 Zheng Jie
*
*  Licensed under the Apache License, Version 2.0 (the "License");
*  you may not use this file except in compliance with the License.
*  You may obtain a copy of the License at
*
*  http://www.apache.org/licenses/LICENSE-2.0
*
*  Unless required by applicable law or agreed to in writing, software
*  distributed under the License is distributed on an "AS IS" BASIS,
*  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
*  See the License for the specific language governing permissions and
*  limitations under the License.
*/
package com.mcx.modules.service;

import com.mcx.modules.domain.Role;
import com.mcx.modules.entity.Role_BackpackItemChangeEntity;
import com.mcx.modules.service.dto.RoleDto;
import com.mcx.modules.service.dto.RoleQueryCriteria;
import org.springframework.data.domain.Pageable;
import java.util.Map;
import java.util.List;
import java.io.IOException;
import javax.servlet.http.HttpServletResponse;

/**
* @website https://el-admin.vip
* @description 服务接口
* @author mcx
* @date 2022-03-22
**/
public interface RoleService {

    /**
    * 查询数据分页
    * @param criteria 条件
    * @param pageable 分页参数
    * @return Map<String,Object>
    */
    Map<String,Object> queryAll(RoleQueryCriteria criteria, Pageable pageable);

    /**
    * 查询所有数据不分页
    * @param criteria 条件参数
    * @return List<RoleDto>
    */
    List<RoleDto> queryAll(RoleQueryCriteria criteria);

    /**
     * 查询多条数据
     * @param ids 条件参数
     * @return List<RoleDto>
     */
    List<RoleDto> findAllById(List<Integer> ids);

    /**
     * 根据ID查询
     * @param id ID
     * @return RoleDto
     */
    RoleDto findById(Integer id);

    /**
    * 创建
    * @param resources /
    * @return RoleDto
    */
    RoleDto create(Role resources);

    /**
    * 编辑
    * @param resources /
    */
    void update(Role resources);

    /**
    * 多选删除
    * @param ids /
    */
    void deleteAll(Integer[] ids);

    /**
     * 穿上装备
     * @param roleId
     * @param goodsId
     * @param goodsServerId
     * @param changeList
     */
    void EquipPutOn(Integer roleId, Integer goodsId, Integer goodsServerId, List<Role_BackpackItemChangeEntity> changeList);

    /**
     * 脱下装备
     * @param roleId
     * @param goodsId
     * @param goodsServerId
     * @param changeList
     */
    void EquipPutOff(Integer roleId, Integer goodsId, Integer goodsServerId, List<Role_BackpackItemChangeEntity> changeList);
}